package Class.Advance.InnerClass.StaticInnerClass;

public class MainClass {
    static int a = 10;
    public int b = 10;

    static class InternalClass{
        public void test1(){
            a = 20;
            //b = 20;   报错，因为静态内部类无法直接访问外部类的非静态成员
            MainClass main = new MainClass();
            main.b = 20;
        }

        public void test2(){
            System.out.println("内部类的非静态成员");
        }

       public static void test3(){
           System.out.println("内部类的静态成员");
       }
    }
}
